package com.pojo.system;

import java.io.Serializable;


public  class COMPPk implements Serializable {

	private static final long serialVersionUID = 1L;

	protected int hashCode = Integer.MIN_VALUE;

	private java.lang.String compno;
	private java.lang.String dep;


	public COMPPk () {}
	
	public COMPPk (
		java.lang.String compno,
		java.lang.String dep) {

		this.setCompno(compno);
		this.setDep(dep);
	}


	/**
	 * Return the value associated with the column: COMPNO
	 */
	public java.lang.String getCompno () {
		return compno;
	}

	/**
	 * Set the value related to the column: COMPNO
	 * @param compno the COMPNO value
	 */
	public void setCompno (java.lang.String compno) {
		this.compno = compno;
	}



	/**
	 * Return the value associated with the column: DEP
	 */
	public java.lang.String getDep () {
		return dep;
	}

	/**
	 * Set the value related to the column: DEP
	 * @param dep the DEP value
	 */
	public void setDep (java.lang.String dep) {
		this.dep = dep;
	}




	public boolean equals (Object obj) {
		if (null == obj) return false;
		if (!(obj instanceof com.pojo.system.COMPPk)) return false;
		else {
			com.pojo.system.COMPPk mObj = (com.pojo.system.COMPPk) obj;
			if (null != this.getCompno() && null != mObj.getCompno()) {
				if (!this.getCompno().equals(mObj.getCompno())) {
					return false;
				}
			}
			else {
				return false;
			}
			if (null != this.getDep() && null != mObj.getDep()) {
				if (!this.getDep().equals(mObj.getDep())) {
					return false;
				}
			}
			else {
				return false;
			}
			return true;
		}
	}

	public int hashCode () {
		if (Integer.MIN_VALUE == this.hashCode) {
			StringBuilder sb = new StringBuilder();
			if (null != this.getCompno()) {
				sb.append(this.getCompno().hashCode());
				sb.append(":");
			}
			else {
				return super.hashCode();
			}
			if (null != this.getDep()) {
				sb.append(this.getDep().hashCode());
				sb.append(":");
			}
			else {
				return super.hashCode();
			}
			this.hashCode = sb.toString().hashCode();
		}
		return this.hashCode;
	}


}